//
//  TrainCell.m
//  Four_Fit_New
//
//  Created by xalo on 16/7/16.
//  Copyright © 2016年 xmaz. All rights reserved.
//

#import "TrainCell.h"
#import "LstAction.h"

@interface TrainCell ()
@property (weak, nonatomic) IBOutlet UIImageView *imageURL;
@property (weak, nonatomic) IBOutlet UILabel *name;
@property (weak, nonatomic) IBOutlet UILabel *duration;

@end

@implementation TrainCell

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

}
- (void)setCellWithModel:(LstAction *)model{
    [self.imageURL layoutIfNeeded];
    self.imageURL.layer.cornerRadius = self.imageURL.width/ 2.0;
    self.imageURL.layer.masksToBounds = YES;
    [self.imageURL sd_setImageWithURL:[NSURL URLWithString:model.imageURL]];
    self.name.text = model.name;
    self.duration.text = [NSString stringWithFormat:@"%@秒钟",model.duration];
}
@end
